package com.ithema.edu.info.manager.dao;


import com.ithema.edu.info.manager.domain.Student;

import java.util.ArrayList;

public class StudentDao2 extends BaseStudentDao {
    private static ArrayList<Student> List = new ArrayList<>();

    public void deleteStudent(int index) {
        List.remove(index);
    }

    public void updateStudent(int index, Student newstudent) {
        List.set(index, newstudent);
    }

    public void addStudent(Student student) {

        List.add(student);
    }


    public ArrayList<Student> queryStudents() {
        return List;
    }


}
